import request from '../utils/request';

export function connect(data) {
  return request({
    url: '/api/ssh/connect',
    method: 'post',
    data,
    headers: {
      'Content-Type': 'application/json',
    },
  });
}

export function sendCommand(data) {
  return request({
    url: '/api/ssh/exec',
    method: 'post',
    data,
    headers: {
      'Content-Type': 'application/json',
    },
  })
}

export function disconnect(data) {
  return request({
    url: '/api/ssh/disconnect',
    method: 'post',
    data,
    headers: {
      'Content-Type': 'application/json',
    },
  })
}
